package gis.lifay.sdk.geoserver;

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStream;
import java.io.InputStreamReader;

/**
 *@ClassName DealProcessStream
 *@Description TODO
 *@Author lifay
 *@Date 2021/11/2 23:26
 **/
public class DealProcessStream extends Thread {
    private InputStream inputStream;

    public DealProcessStream(InputStream inputStream) {
        this.inputStream = inputStream;

    }

    public void run() {
        InputStreamReader inputStreamReader = null;
        BufferedReader br = null;
        try {
            inputStreamReader = new InputStreamReader(inputStream);
            br = new BufferedReader(inputStreamReader);
            //打印信息16 //String line = null;17 //while ((line = br.readLine()) != null) {18 //System.out.println(line);19 //}20 //不打印信息
            while (br.readLine() != null) ;
        } catch (IOException ioe) {
            ioe.printStackTrace();
        } finally {
            try {
                br.close();
                inputStreamReader.close();

            } catch (IOException e) {
                e.printStackTrace();

            }
        }

    }
}